@mixin button-reset {
  border: none;
  font-family: $body-font;
  cursor: pointer;
}

@mixin button-shadow {
  box-shadow: 0 1px 2px 0px rgba(0, 0, 0, 0.25);
}

.button-group {
  display: flex;
  align-items: center;
}

.button {
  @include button-reset;
  color: white;
  background: $blue;
  text-transform: uppercase;
  font-weight: bold;
  height: 24px;
  line-height: 24px;
  border-radius: 3px;
  padding: 0 12px;
  display: inline-block;
  box-shadow: 0 1px 2px 0px rgba(0, 0, 0, 0.25);
  transition: all 100ms;
  cursor: pointer;

  svg {
    fill: white;
    display: block;
    margin: 0 auto;
  }
}

.button:hover {
  background: $blue-dark;
  transform: scale(1.03);
}

.button:focus {
  outline: none;
}

.button:active {
  background: $blue-dark;
  box-shadow: none;
  outline: none;
  transform: scale(1);
}

.button-circle {
  background: $green;
  fill: white;
  stroke: white;
  height: 36px;
  width: 36px;
  border: none;
  box-shadow: $high-box-shadow;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  transition: all 150ms;
  outline: none;

  svg {
    height: 17px;
    width: 17px;
    stroke-width: 0;
  }

  &:hover {
    transform: scale(1.08);
  }

  &:active {
    transform: scale(1);
  }
}

.panel-button {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 6px;
  height: 28px;
  width: 28px;
  background: none;
  border: none;
  border-radius: 3px;
  cursor: pointer;

  svg {
    fill: $gray-4;
    stroke: $gray-4;
    height: 100%;
    width: 100%;
  }

  &:hover {
    transition: background-color 100ms;
    background: rgba(0, 0, 0, 0.05);
  }

  &:active {
    background-color: rgba(0, 0, 0, 0.1);
    transform: translateY(2px);
  }

  &:disabled {
    svg {
      fill: lighten($gray-4, 35%);
      stroke: lighten($gray-4, 35%);
    }
    &:hover {
      background: none;
    }
    &:active {
      box-shadow: none;
      transform: none;
    }
  }

  &.text {
    width: auto;
  }
}

.thin-button {
  @include button-reset;
  font-family: $data-font;
  height: 14px;
  background: #dcdcdc;
  border-radius: 3px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 10px;
  font-size: 11px;
  line-height: 12px;
  font-weight: bold;
  cursor: pointer;

  ˜ &:hover {
    background: darken(#dcdcdc, 5%);
  }

  &:active,
  .active {
    background: darken(#dcdcdc, 10%);
  }
}

.thin-picker {
  width: 22px;
  padding: 0 !important;
  display: flex;
  justify-content: center;
  align-items: center;
  transition: all 100ms;

  svg {
    fill: #4a4a4a;
    width: 8px;
    padding: 0;
    margin: 0;
  }
}

.close-button {
  width: 30px;
  height: 30px;
  padding: 0;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  outline: none;
  background: none;
  position: relative;

  svg {
    height: 10px;
    width: 10px;
    stroke: none;
    fill: lighten($gray-5, 30%);
    transition: fill 50ms;
  }

  &:hover {
    svg {
      fill: $gray-5;
    }
  }

  &:active {
    svg {
      fill: $gray-9;
    }
  }
}
